package com.sg.model.base.po;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import lombok.experimental.Accessors;

import com.sg.framework.common.po.BaseEntity;
import jakarta.validation.constraints.NotNull;

import java.io.Serial;
import java.io.Serializable;
import java.io.Serial;
import java.util.Date;

/**
 * 无空间 无应用
 *
 * @author xxx
 */
@Data
@Accessors(chain = true)
@TableName("oms_framework_users_union")   //1-2-03联盟用户表
public class UsersUnion implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 用户联盟平台激活记录
     */
    @TableId(value = "activate_record_id", type = IdType.ASSIGN_UUID)
    @NotNull(message = "activateRecordId不能为空")
    private String activateRecordId;

    /**
     * 个人账号
     */
    @TableField(value = "user_id")
    @NotNull(message = "个人账号不能为空")
    @Schema(description = "个人账号")
    private String userId;

    /**
     * 联盟应用对象类型 XSZ:新数质 WX:微信 QQ:QQ XL:新浪 LTP:乐天派
     */
    @TableField(value = "union_app_object_type")
    @NotNull(message = "联盟应用对象类型不能为空")
    @Schema(description = "联盟应用对象类型")
    private String unionAppObjectType;

    /**
     * 联盟应用用户ID
     */
    @TableField(value = "union_app_object_id")
    @NotNull(message = "联盟应用用户ID不能为空")
    @Schema(description = "联盟应用用户ID")
    private String unionAppObjectId;

    /**
     * 联盟应用用户名
     */
    @TableField(value = "union_app_object_name")
    @Schema(description = "联盟应用用户名")
    private String unionAppObjectName;

    /**
     * 激活时间
     */
    @TableField(value = "activetion_time")
    @NotNull(message = "激活时间不能为空")
    @Schema(description = "激活时间")
    private Date activetionTime;

    /**
     * 开放ID
     */
    @TableField(value = "open_id")
    @Schema(description = "开放ID")
    private String openId;

    /**
     * 是否作废 TRUE:是 FALSE:否
     */
    @TableField(value = "is_valid")
    @NotNull(message = "是否作废不能为空")
    @Schema(description = "是否作废")
    private String isValid;

    /**
     * 第三方Logo
     */
    @TableField(value = "third_logo")
    @Schema(description = "第三方Logo")
    private String thirdLogo;

    /**
     * 创建于空间ID
     */
    @TableField(value = "space_id")
    @NotNull(message = "创建于空间ID不能为空")
    @Schema(description = "创建于空间ID")
    private String spaceId;

    /**
     * 创建于联盟应用ID
     */
    @TableField(value = "app_id")
    @NotNull(message = "创建于联盟应用ID不能为空")
    @Schema(description = "创建于联盟应用ID")
    private String appId;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    @NotNull(message = "创建时间不能为空")
    @Schema(description = "创建时间")
    private Date createTime;
}
